<template>
	<div id="content">
		<Header />
		<div class="bread">
			<div class="cont w1200">
				<img src="../../../assets/img/location.png" alt=""><a>首页</a> > <a>网谷里</a>> <a>代表建议</a> > <a>建议详情</a>
				<a href="" class="back"><img src="../../../assets/img/back.png" alt=""><router-link
					to="/portal/net/suggestion">返回上一级</router-link></a>
			</div>
		</div>
		<div class="inner">
			<div class="net w1200">
				<h3>建议详情</h3>
				<div class="table p20">
					<div class="table-title">
						<span>编号：{{data.id}}</span>
						<div class="text">人大代表建议详情</div>
					</div>
					<div class="sub-title">
						<div class="line"></div>建议信息
					</div>
					<div class="table-type2">
						<table border="1">
							<tbody>
								<tr>
									<td class="gray" width="10%">会议届次</td>
									<td width="40%">{{ data.meetingSession }}</td>
									<td class="gray" width="10%">提出期间</td>
									<td width="40%">{{data.meetingPeriod}}</td>
								</tr>
								<tr>
									<td class="gray" width="10%">建议人</td>
									<td class="blue" width="40%">{{data.suggesterName}}</td>
									<td class="gray" width="10%">提出日期</td>
									<td width="40%">{{data.proposalDate}}</td>
								</tr>
<!--								<tr>-->
<!--									<td class="gray" width="10%">建议分类</td>-->
<!--									<td width="40%">{{ data.category }}</td>-->
<!--									<td class="gray" width="10%">建议人数</td>-->
<!--									<td width="40%">{{Math.round(data.representativeIds.length/2)}}</td>-->
<!--								</tr>-->
								<tr>
									<td class="gray" width="10%">案由</td>
									<td colspan="3">{{data.brief}}</td>
								</tr>
								<tr>
									<td class="gray" width="10%">办理状态</td>
									<td colspan="3" v-if="data.handlingStatus==0">待审批</td>
                  <td colspan="3" v-if="data.handlingStatus==1">审批中</td>
                  <td colspan="3" v-if="data.handlingStatus==2">已完成</td>
								</tr>
								<tr>
									<td class="gray" width="10%">建议内容</td>
									<td colspan="3">
										<p v-html="data.response"></p>
										<p>
											<iframe width="100%" height="500px" :src="docx"></iframe>
											<!-- <iframe width="100%" height="500px" ref="wordViewer" :src="data.wordFilePath"></iframe> -->
										</p>
									</td>
								</tr>
								<tr>
									<td class="gray" width="10%">附件</td>
									<td colspan="3">
										<a class="file" :href="data.content" download>
											<img src="../../../assets/img/word.png" alt="">{{data.wordFilePath}}
											<!-- <span>227K</span> -->
										</a>
									</td>
								</tr>
<!--								<tr>-->
<!--									<td class="gray" width="10%">办理类型</td>-->
<!--									<td colspan="3">分办</td>-->
<!--								</tr>-->
							</tbody>
						</table>
					</div>
<!--					<div class="sub-title2">-->
<!--						<div class="line"></div>办理情况-->
<!--					</div>-->
<!--					<div class="table-type3">-->
<!--						<table border="1">-->
<!--							<thead>-->
<!--								<tr>-->
<!--									<th>序号</th>-->
<!--									<th width="30%">承办单位</th>-->
<!--									<th>办理方式</th>-->
<!--									<th>签收人</th>-->
<!--									<th>联系电话</th>-->
<!--									<th>办理状态</th>-->
<!--									<th>文号</th>-->
<!--								</tr>-->
<!--							</thead>-->
<!--							<tbody>-->
<!--								<tr>-->
<!--									<td>1</td>-->
<!--									<td class="blue">市委编办</td>-->
<!--									<td>分办</td>-->
<!--									<td>栗荣光</td>-->
<!--									<td>82410126</td>-->
<!--									<td>已签收</td>-->
<!--									<td></td>-->
<!--								</tr>-->
<!--								<tr>-->
<!--									<td>2</td>-->
<!--									<td class="blue">市委编办</td>-->
<!--									<td>分办</td>-->
<!--									<td>栗荣光</td>-->
<!--									<td>82410126</td>-->
<!--									<td>已签收</td>-->
<!--									<td></td>-->
<!--								</tr>-->
<!--							</tbody>-->
<!--						</table>-->
<!--					</div>-->
				</div>
			</div>
		</div>
		<Contact />
	</div>

</template>

<script>
import Header from '@/components/Header';
import Contact from '@/components/Contact';
import { getSuggestionsDetail } from "@/api/website";
export default {
	data() {
		return {
			data: {},
			docx:""
		}
	},
	components: {
		Header,
		Contact
	},
	created() {
      this.getData()
	},
	mounted() {

	},
	methods: {
		getData() {
			getSuggestionsDetail({ id: this.$route.query.id }).then(response => {
				this.data = response.data;
				this.docx = `https://view.officeapps.live.com/op/view.aspx?src=` + encodeURIComponent(response.data.wordFilePath)
			});
		}
	}

};
</script>

<style scoped lang="scss"></style>
